project(energy)

cmake_minimum_required(VERSION 2.8.0)

set(CMAKE_VERBOSE_MAKEFILE FALSE)
set(CMAKE_COLOR_MAKEFILE TRUE)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "../bin")

# build type {Debug|Release}
set(CMAKE_BUILD_TYPE Release)

# do not show Windows command prompt when starting the exe
#set(CMAKE_EXE_LINKER_FLAGS "-Wl,-subsystem,windows")

#FIND_PACKAGE(OpenGL REQUIRED)
SET(QT_QMAKE_EXECUTABLE  "/Users/egs3/QtSDK/Desktop/Qt/4.8.1/gcc/bin/qmake")

#SET(OSG_DIR "/Users/egs3/Frameworks/osg301/")
#message(${OSG_DIR})

#FIND_PACKAGE(OpenSceneGraph REQUIRED
#    osg 
#    osgAnimation 
#    osgDB 
#    #osgFX 
#    osgGA
#    osgManipulator
#    osgShadow 
#    osgSim
#    osgUtil 
#    osgText 
#    osgWidget 
#    osgViewer
#)
        

FIND_PACKAGE(Qt4 COMPONENTS 
    QtCore 
    QtGui 
    QtXml 
    QtWebKit
    QtSql
    QtOpenGl REQUIRED
)

if(QT4_FOUND)
    set( QT_USE_QTOPENGL TRUE )
    include(${QT_USE_FILE})
else(QT4_FOUND)
    message(FATAL_ERROR "Qt4 not found. Please set QT4_DIR.")
endif(QT4_FOUND)

                                           



# Add source and binary directory
add_subdirectory(src bin)
